package com.songlanyun.modules.donation.model;

import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.songlanyun.common.drive.RootEntity;
import com.songlanyun.common.drive.ValueObject;
import lombok.Data;
import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.DecimalMax;
import javax.validation.constraints.DecimalMin;
import javax.validation.constraints.NotBlank;
import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;

/**
 * 公益捐款
 *
 * @author lubo
 * @email sunlightcs@gmail.com
 * @date 2022-07-21 11:32:51
 */
@Data
public class DonationEntityDTO implements ValueObject {
	private static final long serialVersionUID = 1L;


	private Long id;

	private Long userId;
	/**
	 * 联系人
	 */
	@NotBlank(message = "请填写联系人")
	@Length(min = 1, max = 30, message = "联系人只能填写1-30字")
	private String contactPerson;
	/**
	 * 联系电话
	 */
	@NotBlank(message = "请填写联系电话")
	@Length(min = 1, max = 30, message = "联系电话只能填写1-30字")
	private String contactPhone;
	/**
	 * 公司名称，如果是个人可以不填
	 */
	@Length(max = 100, message = "公司名称只能填写100字以内")
	private String companyName;
	/**
	 * 是否是捐款
	 */
	private Boolean isDonation;
	/**
	 * 是否是捐物
	 */
	private Boolean isOffering;
	/**
	 * 意向物品的名称
	 */
	@Length(max = 200, message = "意向物品的名称只能填写200字以内")
	private String itemName;
	/**
	 * 意向金额
	 */
	@DecimalMin(value = "0",message = "意向金额最小0元")
	@DecimalMax(value = "99999999",message = "意向金额最大99999999元")
	private BigDecimal interestAmount;




}
